<div id="ad_#{$config.id}">
  <div class="flash_img">
    <ul>
	#{foreach from=$ads.items item=ad}
    	<li class="smask">
    		<a href="#{$ad.url}" target="#{$ad.target}">
    			<img class="auto_img" src="#{res file=$ad.path thumb=50x50}"/>
    		</a>
    		<a href="#{$ad.url}" target="#{$ad.target}">#{$ad.title}</a>
			<p>#{$ad.summary}</p>
    	</li>
	#{/foreach}
  </div>
  <ul class="flash_item" style="width:#{$ads.width}px;height:#{$ads.height}px;display:inline-block;">
	#{foreach from=$ads.items item=ad}
    <li><a href="#{$ad.url}" target="#{$ad.target}"><img src="#{res file=$ad.path}"/></a></li>
	#{/foreach}
  </ul>
</div>
<script>
$(function(){
	$('#ad_#{$config.id}').ADSlide({
       	speed : "normal",
		num : #{$ads.items|count},
		timer : 3000,
		flowSpeed:300
   	});
});
</script>